<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
         div.box{
            width: 600px;
            height: 600px;
            border: 5px solid gray;
            display: grid;

            /* 直接写死 */
            grid-template-rows: 200px 180px 180px;
            grid-template-columns: 200px 180px 180px;

             /* 分开写 */
            /* grid-row-gap:20px;
            grid-column-gap:20px */

            /* 合并 */
            /* grid-gap: 20px; */
            
            /* 省略写 */
            gap: 20px 20px;
        }
        .box div{
            border: 1px solid red;
        }
    </style>
</head>
<body>
    <div class="box">
        <div>1</div>
        <div>2</div>
        <div>3</div>
        <div>4</div>
        <div>5</div>
        <div>6</div>
        <div>7</div>
        <div>8</div>
        <div>9</div>
    </div>
</body>
</html>